# ClientID.Debug


# Properties

| Data Type | Property Name | Default Value | Description |
| --- | --- | --- | --- |
| Boolean | `ClientID.Debug.ENABLED` | false | Enable/disable debug mode. |


# Methods

## `print`

Prints a debug message to the console.

**Signature:**

```Lua
ClientID.Debug:print( msg )
```

**Returns:** None.

**Parameters:**

1. (String) The message.


# ClientID.Game


# Methods

## `IsVerified`

Checks whether the player is verified.

**Signature:**

```Lua
ClientID.Game:IsVerified( player )
```

**Returns:** True if verified. Otherwise, returns false.

**Parameters:**

1. (Player object) The player.


## `GetID`

Returns the player's assigned unique identity.

**Signature:**

```Lua
ClientID.Game:GetID( index )
```

**Returns:**

* (Integer) The player identity.

  **or**

* `nil` if invalid index or unassigned. 

**Parameters:**

1. (Integer) The player entity index.


## `SetID`

Sets the player's identity.

**Signature:**

```Lua
ClientID.Game:SetID( index , value )
```

**Returns:** None.

**Parameters:**

1. (Integer) The player entity index.

2. (Integer) The new identity.


# Hookable Events

## OnVerify

Called when the player is verified or not verified.

**Signature:**

```Lua
ClientID.Game:OnVerify( player, isVerified )
```

**Parameters:**

1. (Player object) The player.

2. (Boolean) True if player is verified. Otherwise, returns false.


# Subroutines

## OnPlayerSignal hook

Internal essential function.

If you are overriding `Game.Rule:OnPlayerSignal`, then calls this function inside of it.

Failed to do so causing the library malfunction.

**Signature:**

```Lua
ClientID.Game:OnPlayerSignal( player, signal )
```

## OnUpdate hook

Internal essential function.

If you are overriding `Game.Rule:OnUpdate`, then calls this function inside of it.

Failed to do so causing the library malfunction.

**Signature:**

```Lua
ClientID.Game:OnUpdate( time )
```


# ClientID.UI


# Properties

| Data Type | Property Name | Default Value | Description |
| --- | --- | --- | --- |
| Float | `ClientID.UI.VERIFY_DELAY` | 1.5 | Identity verification delay. Increases this value if the client get frequent verification failures. |


# Methods

## `GetID`

Returns the player's unique identity.

**Signature:**

```Lua
ClientID.UI:GetID()
```

**Returns:**

* (Integer) The player identity.

  **or**

* `nil` if not verified or unassigned. 

**Parameters:** None.


## `GetGameTime`

Returns current game time.

**Signature:**

```Lua
ClientID.UI:GetGameTime()
```

**Returns:**

* (Float) The current game time.

  **or**

* `nil` if not synchronized with server. 

**Parameters:** None.


## `IsVerified`

Checks whether the player identity is verified.

**Signature:**

```Lua
ClientID.UI:IsVerified()
```

**Returns:** (Boolean) True if verified. Otherwise, returns false. 

**Parameters:** None.


## `IsVerificationStarted`

Checks whether the identity verification has started.

**Signature:**

```Lua
ClientID.UI:IsVerificationStarted()
```

**Returns:** (Boolean) True if started. Otherwise, returns false. 

**Parameters:** None.


## `Assign`

Assigns the player identity with given game time.

**Signature:**

```Lua
ClientID.UI:Assign( time )
```

**Returns:** None.

**Parameters:** 

1. (Float) The game time.


## `StartVerification`

Starts the identity verification process.

**Signature:**

```Lua
ClientID.UI:StartVerification()
```

**Returns:** None.

**Parameters:** None.


## `StopVerification`

Stop the identity verification process.

**Signature:**

```Lua
ClientID.UI:StopVerification()
```

**Returns:** None.

**Parameters:** None.


# Hookable Events

## OnVerify

Called when the player is verified or not verified.

**Signature:**

```Lua
ClientID.UI:OnVerify( isVerified )
```

**Parameters:**

1. (Boolean) True if player is verified. Otherwise, returns false.


# Subroutines

## "ClientIdentifier.Verify" OnSync hook

Internal essential function.

If you are overriding `"ClientIdentifier.Verify":OnSync`, then calls this function inside of it.

Failed to do so causing the library malfunction.

**Signature:**

```Lua
ClientID.SyncValue.Verify:OnSync()
```

## "ClientIdentifier.CurrentTime" OnSync hook

Internal essential function.

If you are overriding `"ClientIdentifier.CurrentTime":OnSync`, then calls this function inside of it.

Failed to do so causing the library malfunction.

**Signature:**

```Lua
ClientID.SyncValue.CurrentTime:OnSync()
```


# ClientID.SyncValue


# Properties

| Data Type | Property Name | Default Value | Description |
| --- | --- | --- | --- |
| String | `ClientID.SyncValue.Get.NAME` | "ClientIdentifier.Get" | `Get` sync variable name. |
| String | `ClientID.SyncValue.GetAll.NAME` | "ClientIdentifier.GetAll" | `GetAll` sync variable name. |
| String | `ClientID.SyncValue.Verify.NAME` | "ClientIdentifier.Verify" | `Verify` sync variable name. |
| String | `ClientID.SyncValue.CurrentTime.NAME` | "ClientIdentifier.CurrentTime" | `CurrentTime` sync variable name. |
| SyncValue object | `ClientID.SyncValue.Get.Instance` | nil | Instance of `Get` sync variable name. |
| SyncValue object | `ClientID.SyncValue.GetAll.Instance` | nil | Instance of `GetAll` sync variable name. |
| SyncValue object | `ClientID.SyncValue.Verify.Instance` | nil | Instance of `Verify` sync variable name. |
| SyncValue object | `ClientID.SyncValue.CurrentTime.Instance` | nil | Instance of `CurrentTime` sync variable name. |


# ClientID.Enum


# ClientID.Enum.SIGNAL

# Properties

| Data Type | Property Name | Default Value | Description |
| --- | --- | --- | --- |
| Integer | `ClientID.Enum.SIGNAL.OK` | 2000000000 | Signal code for assigning new identity. |
| Integer | `ClientID.Enum.SIGNAL.GET` | 1547109793 | Signal code to get current player identity. |
| Integer | `ClientID.Enum.SIGNAL.GET_ALL` | 1547109779 | Signal code to get all player identities. |
| Integer | `ClientID.Enum.SIGNAL.VERIFY` | 1547109749 | Signal code to verify current player identity. |

